fix: resolve settings API 500 errors#915
Conversation
|
@Shravani-36 is attempting to deploy a commit to the PRIYANSHU DOSHI's projects Team on Vercel. A member of the Team first needs to authorize it. |
GSSoC Label Checklist 🏷️@Priyanshu-byte-coder — please apply the appropriate labels before merging: Difficulty (pick one):
Quality (optional):
Validation (required to score):
|
There was a problem hiding this comment.
Thanks for your first PR on DevTrack! 🎉
A maintainer will review it within 48 hours. While you wait:
- Make sure CI is passing (type-check + lint)
- Double-check the PR description is filled out and the issue is linked
- Feel free to ask questions in Discussions if you need help
If you find DevTrack useful, a ⭐ star on the repo is always appreciated — it helps the project grow and attract more contributors!
9c69cb5
into
Priyanshu-byte-coder:main
|
🎉 Merged! Thanks for contributing to DevTrack. If the project has been useful to you, a ⭐ star on the repo is the easiest way to support it — it helps DevTrack get discovered by more developers. Keep an eye on open issues for your next contribution! |
PR #915 squash-merge left branch names embedded as code artifacts ('fix-settings-api-500' and 'main') and duplicate function bodies in getUserByUsername and updateUserPublicFlag. This caused TS errors TS1005 and TS1472 breaking CI on main. Clean rewrite keeps the PR #915 version (try/catch error handling, leaderboard_opt_in in select) with no duplicate or artifact code. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Summary
Fixed the Settings API routes that were returning
500 Internal Server Erroron the deployed dashboard.This update improves Supabase user resolution and adds safer error handling for settings-related API routes so the Settings page loads correctly.
Closes #476
Type of Change
Changes Made
resolveAppUser/dashboard/settingsloads successfully locallyHow to Test
Steps for the reviewer to verify this works:
.env.localSign in with GitHub
Verify:
Screenshots (if UI change)
N/A
Checklist
npm run lintpasses locallynpm run type-check)